<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>伪类简单使用</title>
  <style type="text/css">
    p:before{
      content: "Chocolate";
    }

    p:after{
      content: "写博客！";
    }
  </style>
</head>
<body>
  <p>喜欢</p>
</body>
</html>